import { createApp } from 'vue'
import App from './App.vue'
import './assets/main.css'
// 预览组件以及样式
import VMdPreview from '@kangc/v-md-editor/lib/preview'
import '@kangc/v-md-editor/lib/style/preview.css'
// emoji
import createEmojiPlugin from '@kangc/v-md-editor/lib/plugins/emoji/index'
import '@kangc/v-md-editor/lib/plugins/emoji/emoji.css'
// VuePress主题以及样式（这里也可以选择github主题）
import vuepressTheme from '@kangc/v-md-editor/lib/theme/vuepress.js'
import '@kangc/v-md-editor/lib/theme/style/vuepress.css'
// Prism
import Prism from 'prismjs'
// 代码高亮，按需导入
import 'prismjs/components/prism-json'
import 'prismjs/components/prism-java'
import 'prismjs/components/prism-javascript'
import 'prismjs/components/prism-typescript'
import 'prismjs/components/prism-python'
import 'prismjs/components/prism-lua'
import 'prismjs/components/prism-sql'
import 'prismjs/components/prism-yaml'
import 'prismjs/components/prism-xml-doc'
import 'prismjs/components/prism-bash'
import 'prismjs/components/prism-properties'

// 选择使用主题
VMdPreview.use(vuepressTheme, { Prism })

// emoji表情
VMdPreview.use(createEmojiPlugin())

const app = createApp(App)
app.use(VMdPreview)
app.mount('#app')
